#ifndef __CALC_LIB_H
#define __CALC_LIB_H
#include "MemSys.h"

#define TSR_OK					0

#define TSE_UNKNOWN				1
#define TSE_LIB_VERSION			2
#define TSE_SP_VERSION			3
#define TSE_SP_BADDATA			4
#define TSE_INIT_MEMOUT			5
#define TSE_SSP_BADDATA			6
#define TSE_SSP_MEMOUT			7
#define TSE_SSP_NOTEXIST		8

#define TSW_CONFIG_UNKNOWN		100
#define TSW_CONFIG_VER			101
#define TSW_CONFIG_CALI			102
#define TSW_CONFIG_BADDATA		103
#define TSW_CALC_MEMOUT			104
#define TSW_CALC_NOPOINT		105
#define TSW_NOREPORT			106
#define TSW_RESTART				107
#define TSW_EMPTY_REPORT		132

#define RW_UCHAR(pFileBuffer)					(*((unsigned char*)(pFileBuffer)))
#define RW_SHORT(pFileBuffer)					(*((signed short*)(pFileBuffer)))
#define RW_USHORT(pFileBuffer)					(*((unsigned short*)(pFileBuffer)))
#define RW_INT(pFileBuffer)						(*((int*)(pFileBuffer)))				
#define RW_UINT(pFileBuffer)					(*((unsigned int*)(pFileBuffer)))


#endif

